#include<iostream>
using namespace std;
#include<string>
#include<fstream>

int main()
{
  ofstream ofs("./log.txt",ios::out | ios::binary);
  if(!ofs.is_open())
  {
    cerr<<"open error"<<endl;
  }
  string msg = "hello world\n";
  ofs.write(msg.c_str(),msg.size());
  ofs.write(msg.c_str(),msg.size());
  ofs.write(msg.c_str(),msg.size());
  ofs.write(msg.c_str(),msg.size());
  ofs.write(msg.c_str(),msg.size());
  ofs.close();
  return 0;
}
